package com.ssd.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ssd.entity.VendingMachineEntity;
import com.ssd.entity.VmTypeEntity;
import org.apache.ibatis.annotations.*;

import java.util.Map;

@Mapper
public interface VMTypeDao extends BaseMapper<VmTypeEntity> {


    @Select("<script>" +
            "SELECT * " +
            "FROM tb_vm_type " +
            "</script>")
    @Results({
            @Result(property="typeId", column="type_id"),
            @Result(property="vmRow", column="vm_row"),
            @Result(property="vmCol", column="vm_col"),
            @Result(property="name", column="name"),
            @Result(property="channelMaxCapacity", column="channel_max_capacity"),
            @Result(property="model", column="model"),
            @Result(property="image", column="image")
    })
    Page<VmTypeEntity> selectVMType(Page<?> page);
}